<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>高度坍塌</title>
<style type="text/css">
	#gd1{
		width: 100px;
		border: 2px solid red;
	}
	#gd1>.gd2{
		height: 48px;
		width: 48px;
		border: 1px solid black;
		float: left;
	}
	#gd3{
	    /* 克服高度坍塌 */
		clear: both;
		height: 2px;
		background-color: yellow;
	}
</style>
</head>
<body>
	<div id="gd1">
		<div class="gd2"></div>
		<div class="gd2"></div>
		<div class="gd2"></div>
		<div class="gd2"></div>
		<div id="gd3"></div>
	</div>
</body>
</html>





